function NumericStepper(vl){
	InputTextDouble.apply(this,[vl]);
	this.setIcon("circle-arrow-up");
	this.setIcon("circle-arrow-down",2);
	this.htmlX.addClass("NumericStepper");
	this.maxvl = 9999;
	this.minvl = -9999;
	this.stepvl = 1;
	this.htmlX[0]["dta"] = this; 
   	this.htmlX.find(".addon2").click($.proxy(this.diminuir,this));
	this.htmlX.find(".addon1").click($.proxy(this.aumentar,this));
}

NumericStepper.prototype = Object.create(InputTextDouble.prototype);
NumericStepper.prototype.constructor = NumericStepper;

NumericStepper.prototype.getVL = function(){	
	return parseInt(this.getValue());
};
NumericStepper.prototype.setVL = function(vl){	
	if(vl >= this.minvl && vl <= this.maxvl){
		this.setValue(parseInt(vl));
		this.htmlX.find(".inputtt").change();
	}
};
NumericStepper.prototype.aumentar = function(){
	this.setVL(this.getVL()+this.stepvl);
};
NumericStepper.prototype.diminuir = function(){	     
	this.setVL(this.getVL()-this.stepvl);
};
NumericStepper.prototype.setMin = function(vl){	     
	this.minvl = vl;
};
NumericStepper.prototype.setMax = function(vl){	     
	this.maxvl = vl;
};
NumericStepper.prototype.setStep = function(vl){	     
	this.stepvl = vl;
};

function InputMoney(vl){	
	InputTextDouble.apply(this,[vl]);
	this.setAddonText("$",1);
	this.setAddonText(",00",2);
	this.setSize(3);
	this.htmlX.addClass("InputMoney");
	this.htmlX[0]["dta"] = this; 
}
InputMoney.prototype = Object.create(InputTextDouble.prototype);
InputMoney.prototype.constructor = InputMoney;


function InputEmail(vl){	
	InputText.apply(this,[vl]);
	//this.setIcon("icon-email");
	this.htmlX.addClass("InputEmail");
	this.setAddonText("@");	
	this.setSize(6);
	this.htmlX[0]["dta"] = this;
}
InputEmail.prototype = Object.create(InputText.prototype);
InputEmail.prototype.constructor = InputEmail;

function InputTime(vl){	
	InputText.apply(this,[vl]);
	this.htmlX.addClass("InputTime");
	this.setIcon("time");
	this.setSize(2);
	this.setMaxLength(5);
	this.htmlX[0]["dta"] = this;
}
InputTime.prototype = Object.create(InputText.prototype);
InputTime.prototype.constructor = InputTime;

function InputPercent(vl){
	InputTextDouble.apply(this,[vl]);
	this.setAddonText("%");
	this.setAddonText(".00",2);
	this.setSize(3);
	this.htmlX.addClass("InputPercent");
	this.htmlX[0]["dta"] = this;
}
InputPercent.prototype = Object.create(InputTextDouble.prototype);
InputPercent.prototype.constructor = InputPercent;

function InputPhone(pddd){
	InputText.apply(this,["(0"+pddd+")"]);
	this.setIcon("earphone");
	//this.setAddonText("i");
	this.htmlX.addClass("InputPhone");
	this.htmlX[0]["dta"] = this;
	this.setSize(3);
}
InputPhone.prototype = Object.create(InputText.prototype);
InputPhone.prototype.constructor = InputPhone;
